﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;

namespace Project1.Common
{
    /// <summary>
    /// 公共常量
    /// </summary>
    public class ConstValue
    {


        #region 测量部分
    
        public const int BEGINNUM = 10000;
        public const int MEASURE_ERROR = -1;
        public const int MEASURE_OK = 999;
        public const int MEASURE_CIRCLE = BEGINNUM;
        public const int MEASURE_CIRCLE2 = BEGINNUM + 1;
        public const int MEASURE_LINE = BEGINNUM + 2;
        public const int MEASURE_LINE_PEAK = BEGINNUM + 3;
        public const int MEASURE_POINT = BEGINNUM + 4;
        public const int MEASURE_POINT_PEAK = BEGINNUM + 5;
        public const int MEASURE_LL_Cross = BEGINNUM + 6;//线线交点
        public const int MEASURE_LC_Cross = BEGINNUM + 7; //线圆交点
        public const int MEASURE_CC_Cross = BEGINNUM + 8;//圆圆交点
        public const int MEASURE_P_Mid = BEGINNUM + 9;
        public const int MEASURE_LL_Mid = BEGINNUM + 10;//平分线
        public const int MEASURE_PL_Mid = BEGINNUM + 11;//点线中线
        public const int MEASURE_PP_Mid = BEGINNUM + 12;//点点中线
        public const int MEASURE_PL_VERTICAL = BEGINNUM + 13;//垂线
        public const int MEASURE_PL_Parallel = BEGINNUM + 14; //平行线
        public const int MEASURE_P_FitLine = BEGINNUM + 15;//拟合直线
        public const int MEASURE_LL_Concate = BEGINNUM + 16;
        public const int MEASURE_LL_InnerC = BEGINNUM + 17;//内切圆
        public const int MEASURE_CC_Mid = BEGINNUM + 18; //中间圆
        public const int MEASURE_C_SUP = BEGINNUM + 19;//辅助圆
        public const int MEASURE_C_Fit = BEGINNUM + 20;//近似圆
        public const int MEASURE_Arc_Concat = BEGINNUM + 21; //弧线的结合
        public const int MEASURE_PP_DIST = BEGINNUM + 22; //点点距离
        public const int MEASURE_PL_DIST = BEGINNUM + 24;//点线距离
        public const int MEASURE_LL_Dist  = BEGINNUM + 25;//线线距离
        public const int MEASURE_PC_DIST = BEGINNUM + 26;//点圆距离
        public const int MEASURE_LC_DIST =  BEGINNUM + 27;//线圆距离
        public const int MEASURE_CC_DIST = BEGINNUM + 28;//圆圆距离
        public const int MEASURE_C_RADIUS = BEGINNUM + 29;//圆径
        public const int MEASURE_ARC_ANGLE = BEGINNUM + 30;//弧度
        public const int MEASURE_LL_ANGLE = BEGINNUM + 31;//线夹角度
        public const int LINE = BEGINNUM + 32;
        public const int POINT = BEGINNUM + 33;
        public const int CIRCLE = BEGINNUM + 34;

        public const int DISTANCE = BEGINNUM + 35;
        public const int ANGLE = BEGINNUM + 36;
        public const int LOAD_ELEM_LL = BEGINNUM + 37;
        public const int LOAD_ELEM_LC = BEGINNUM + 38;
        public const int LOAD_ELEM_CC = BEGINNUM + 39;
        public const int LOAD_ELEM_PL = BEGINNUM + 40;
        public const int LOAD_ELEM_PP = BEGINNUM + 41;

        public const int MEASURE_C_Center = BEGINNUM + 42;//圆心
        public const int SUPLINE = BEGINNUM + 43;//圆心
        public const int ROI_RECTANGLE = BEGINNUM + 44;
        public const int ROI_CIRCLE = BEGINNUM + 45;
        public const int ROI_LINE = BEGINNUM + 46;
        #endregion


        #region 元素标识
        public const string ELEM_CIRCLE = "ELEM_CIRCLE";
        public const string ELEM_POINT = "ELEM_POINT";
        public const string ELEM_LINE = "ELEM_LINE";
        #endregion

        #region 其他
        public const string MOUSEEVENT = "MouseEvent";
        public const string MAX_RADIUS = "MAX_RAIDUS";
        public const string MIN_RADIUS = "MIN_RADIUS";
        public const string MIN_THRESHOLD = "MIN_THRESHOLD";
        public const string MAX_THRESHOLD = "MAX_THRESHOLD";
        public const string MODE = "MODE";
        public const string REGION = "REGION";
        public const string CONTOUR = "CONTOUR";
        public const string RADIUS = "RADIUS";
        public const string MODULE = "MODULE";
        public const string IMG = "IMG";
        public const string EMPTY_ELEMLIST = "EMPTY_ELEMLIST";
        public const string UPDATE_ELEMLIST = "UPDATE_ELEMLIST";
        public const string PEAK_CIRCLE = "PEAK_CIRCLE";
        public const string PEAK_LINE = "PEAK_LINE";
        public const string PEAK_POINT = "PEAK_POINT";
        public const string SELECTED_COLOR = "green";
        public const string UNSELECTED_COLOR = "blue";
        public const string SUPLINE_COLOR = "yellow";
        public const string SUPLINE_COLOR2 = "black";
        public const string TYPE_LINEPACK = "Project1.Element.LinePack";
        public const string TYPE_CIRCLEPACK = "Project1.Element.CirclePack";
        public const string TYPE_POINTPACK = "Project1.Element.PointPack";
        public enum Counter
        {
            峰值点,
            峰值圆,
            点,
            线,
            峰值线,
            线线角度,
            线线拼接,
            线线交点,
            线线距离,
            线线内切圆,
            线线中线,
            点线距离,
            点线中线,
            点线平分,
            点线垂线,
            点点距离,
            点点中线,
            点拟合线,
            圆圆交点,
            圆圆距离,
            圆圆中心圆,
            线圆交点,
            线圆距离,
            圆径,
            圆心,
            圆弧拼接,
            圆弧角度
        }

        #endregion

        #region 事件
        public const int BEGINNUM2 = 11000;
        public const int Adapt = BEGINNUM2 + 1;
        public const int Zoom = BEGINNUM2 +2;
        public const int MouseUp = BEGINNUM2 + 3;
        public const int MouseMove = BEGINNUM2 +4;
        public const int MouseDown = BEGINNUM2 + 5;

        #endregion

        #region 提示语
        public const string CIRCLETIP = "左键点击屏幕生成圆形ROI区域，右键清除ROI区域，调整后点击应用查看检测结果，点击确定保存";
        public const string POINTTIP = "左键点击屏幕后生成直线ROI，右键清除ROI区域，调整后点击应用查看检测结果，点击确定保存";
        public const string LINETIP = "左键点击屏幕后生成矩形ROI，右键清除ROI区域，调整后点击应用查看检测结果，点击确定保存";
        public const string CCTIP = "左键点击屏幕选择两个圆，右键重置，调整后点击应用查看检测结果，点击确定保存";
        public const string LCTIP = "左键点击屏幕选择一个圆和一条线，右键重置，调整后点击应用查看检测结果，点击确定保存";

        public const string C_RADIUSTIP = "左键点击屏幕选择圆的轮廓，右键重置，调整后点击应用查看检测结果，点击确定保存";

        public const string C_CENTERTIP = "左键点击屏幕选择圆的轮廓，右键重置，调整后点击应用查看检测结果，点击确定保存";
        public const string LLTIP = "左键点击屏幕选择两条线，右键重置，调整后点击应用查看检测结果，点击确定保存";
        public const string PLTIP = "左键点击屏幕选择一个点和一条线,右键重置，调整后点击应用查看检测结果，点击确定保存";
        public const string PPTIP = "左键点击屏幕选择两个点,右键重置,调整后点击应用查看检测结果，点击确定保存";
        public const string PTIP = "选择若干个点,右键重置,调整后点击应用查看检测结果，点击确定保存";
        public const string ARCTIP = "选择若干个圆弧,右键重置,调整后点击应用查看检测结果，点击确定保存";

        #endregion

        #region 绘制ROI区域
        public const string DRAW_RECTANGLE1 = "DRAW_RECTANGLE1";
        public const string DRAW_RECTANGLE2 = "DRAW_RECTANGLE2";
        public const string DRAW_CIRCLE = "DRAW_CIRCLE";
        public const string DRAW_ELLIPSE = "DRAW_ELLIPSE";
        public const string DRAW_LINE = "LINE";
        public const string RECT_ROW = "RECT_ROW";
        public const string RECT_COLUMN = "RECT_COLUMN";
        public const string RECT_PHI = "RECT_PHI";
        public const string RECT_LEN1 = "RECT_LEN1";
        public const string RECT_LEN2  = "RECT_LEN2";
        public const string CIRCLE_RADIUS = "CIRCLE_RADIUS";
        public const string CIRCLE_ROW = "CIRCLE_ROW";
        public const string CIRCLE_COLUMN = "CIRCLE_COLUMN";
        public const string LINE_BEGIN_ROW = "LINE_BEGIN_ROW";
        public const string LINE_BEGIN_COLUMN = "LINE_BEGIN_COLUMN";
        public const string LINE_END_ROW = "LINE_END_ROW";
        public const string LINE_END_COLUMN = "LINE_END_COLUMN";
        #endregion

    }
}
